#ifndef TASK_H
#define TASK_H

#include <QObject>
#include <QRunnable>

class Task : public QObject, public QRunnable //如果要使用信号槽机制，需要继承自QObject
{
    Q_OBJECT
public:
    Task();
    ~Task();
    void SetIdx(int idx);

private:
    void run() override;

private:
    int idx_;
};

#endif // TASK_H
